package lambda.examples._01;

public class App {
	public static void main(String[] args) throws Exception {
		new Thread(() -> {
			while (true) {
				try {
					Thread.sleep(1000);
				} catch (InterruptedException e) {
					e.printStackTrace();
				}
				System.out.println("A:" + Thread.currentThread().getName());
			}
		}).start();

		new Thread(() -> {
			while (true) {
				try {
					Thread.sleep(1000);
					System.out.println("B:" + Thread.currentThread().getName());
				} catch (InterruptedException e) {
					e.printStackTrace();
				}
			}
		}).start();

	}
}
